function check_file {
    ls "$1"
    return $? 
}
check_file "example.txt"
echo "The function returned with exit code $?"
